import request from '@/config/axios'

class Article {
	getArticle(data : any) : Ajax.PromiseAxiosResponse<any> {
		return request.get({
			url: '/article/getArticle', params:data
		})
	}
	getSwiper() : Ajax.PromiseAxiosResponse<any> {
		return request.get({
			url: '/article/getSwiper'
		})
	}
	getDetail(data : any) : Ajax.PromiseAxiosResponse<any> {
		return request.get({
			url: '/article/getDetail',params:data
		})
	}
	addArticle(data : any) : Ajax.PromiseAxiosResponse<any> {
		return request.post({
			url: '/article/addArticle',data
		})
	}
	love(data : any) : Ajax.PromiseAxiosResponse<any> {
		return request.get({
			url: '/article/love',params:data
		})
	}
}

export const ArticleApi = new Article()